#include "BPlay.h"

#undef PlaySound

BPlay::BPlay()
{
	m_name = "Play Sound";
	m_clicked = false;
	m_mouseButtonWasReleased = false;
	//TheSoundManager::Instance()->LoadSound("../../Assets/pistol.wav");
}

BPlay::~BPlay()
{

}

void BPlay::Update()
{
	m_pos.y = -0.9f;
	m_pos.x = -0.6f;

	if (m_mouseDidIntersect && m_mouseButtonWasReleased)
	{
		m_sound->Play();

		m_mouseButtonWasReleased = false;
		m_mouseDidIntersect = false;
	}
}